package vip.ablog.xmall.product.service;

import com.baomidou.mybatisplus.extension.service.IService;
import vip.ablog.common.utils.PageUtils;
import vip.ablog.xmall.product.entity.CategoryEntity;
import vip.ablog.xmall.product.vo.Catelog2Vo;

import java.util.List;
import java.util.Map;

/**
 * 商品三级分类
 *
 * @author jsp
 * @email jsp@gmail.com
 * @date 2020-08-10 15:58:12
 */
public interface CategoryService extends IService<CategoryEntity> {

    PageUtils queryPage(Map<String, Object> params);

    List<CategoryEntity> listWithTree();

    void removeMenuByIds(List<Long> catIds);

    /***
     * 找到catelogid的完整路径
     * 【父路径/子路径/孙子路径】
     * @param attrGroupId
     * @return
     */
    Long[] findCatelogPath(Long attrGroupId);

    void updateCascade(CategoryEntity category);
    List<CategoryEntity> getLevel1Categorys();

    Map<String, List<Catelog2Vo>> getCatalogJson();
}

